$OpenBSD: patch-configure_ac,v 1.6 2013/09/24 08:39:04 ajacoutot Exp $
--- configure.ac.orig	Fri Jul 19 06:24:09 2013
+++ configure.ac	Tue Sep 24 10:29:59 2013
@@ -141,6 +141,14 @@ dnl --------------------------------------------------
 CK_BACKEND=""
 KVM_LIBS=""
 case "$host" in
+       *-*-openbsd*)
+       CK_BACKEND="openbsd"
+        AC_CHECK_LIB(kvm, kvm_openfiles, have_kvm=yes,
+                AC_MSG_ERROR([Unable to find libkvm which is needed on OpenBSD]))
+        if test "x$have_kvm" = "xyes"; then
+                KVM_LIBS="-lkvm"
+        fi
+        ;;
         *-*-freebsd* | *-*-kfreebsd*-gnu)
         CK_BACKEND="freebsd"
         AC_CHECK_LIB(kvm, kvm_openfiles, have_kvm=yes,
@@ -167,6 +175,7 @@ AC_SUBST(KVM_LIBS)
 
 AM_CONDITIONAL(CK_COMPILE_LINUX, test x$CK_BACKEND = xlinux, [Compiling for Linux])
 AM_CONDITIONAL(CK_COMPILE_FREEBSD, test x$CK_BACKEND = xfreebsd, [Compiling for FreeBSD])
+AM_CONDITIONAL(CK_COMPILE_OPENBSD, test x$CK_BACKEND = xopenbsd, [Compiling for OpenBSD])
 AM_CONDITIONAL(CK_COMPILE_SOLARIS, test x$CK_BACKEND = xsolaris, [Compiling for Solaris])
 AM_CONDITIONAL(CK_COMPILE_GNU, test x$CK_BACKEND = xgnu, [Compiling for GNU])
 AC_SUBST(CK_BACKEND)
@@ -388,6 +397,7 @@ src/Makefile
 tools/Makefile
 tools/linux/Makefile
 tools/freebsd/Makefile
+tools/openbsd/Makefile
 tools/solaris/Makefile
 data/Makefile
 doc/Makefile
